package com.self.match.model;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.jetbrains.annotations.NotNull;

import java.math.BigDecimal;

/**
 * @version v1.0
 * @ClassName: DepthItemVo
 * @Description:
 * @Author: Mac
 */
@NoArgsConstructor
@Data
@AllArgsConstructor
public class DepthItemVo implements Comparable<DepthItemVo>{
    private BigDecimal price = BigDecimal.ZERO;
    private BigDecimal volume = BigDecimal.ZERO;

    @Override
    public int compareTo(@NotNull DepthItemVo itemVo) {
        return this.price.compareTo(itemVo.getPrice());
    }
}
